{include file="default/base/header" /}
<link rel="stylesheet" href="{$Think.HOME_SITE_ROOT}/css/Seller.css">
<link rel="stylesheet" href="{$Think.PLUGINS_SITE_ROOT}/js/jquery.lightbox/css/lightbox.min.css">
<script src="{$Think.PLUGINS_SITE_ROOT}/js/jquery.lightbox/js/lightbox.min.js"></script>
<div class='page'>
    <table class="ds-default-table">
        <thead>
        <tr>
            <th colspan="6">基本信息</th>
        </tr>
        </thead>
        <tbody>
        <tr class="noborder">
            <th class="required w120"><label class="" for="contract_name">头像:</label></th>
            <td colspan="3">{if $data.avtar}<img src="{$data.avtar}" width="70"/>{else/} 未上传{/if}</td>
        </tr>
        <tr class="noborder">
            <th class="required w120"><label class="" for="contract_name">手机号/账号:</label></th>
            <td>{$data.phone}</td>
            <th>邀请码：</th>
            <td>{$data.code}</td>
        </tr>
        <tr class="noborder">
            <th class="required w120"><label class="" for="contract_name">技能类型:</label></th>
            <td>{$skillArr.name}</td>
            <th class="required w120"><label class="" for="contract_name">工作时间:</label></th>
            <td>{php}
                if($data['startweek']){
                echo $weekArr[$data['startweek']];
                }
                if($data['endweek']){
                echo '至';
                echo $weekArr[$data['endweek']];
                }
                {/php}
                {$data['starttime']}-{$data['endtime']}
            </td>
        </tr>
        <tr class="noborder">
            <th class="required w120"><label class="" for="contract_name">邀请人:</label></th>
            <td>{$data.prevcode}</td>
            <th>邀请人类型：</th>
            <td>{if $data.prevtype==3}客户邀请{elseif $data.prevtype==4}服务人员邀请
                {elseif $data.prevtype==2}运营商邀请{elseif $data.prevtype==1}
                {if $data.admin_id}后台添加{else/}注册{/if}{/if}
            </td>
        </tr>
        <tr class="noborder">
            <th class="required w120"><label class="" for="contract_name">余额:</label></th>
            <td>{$data.money}元</td>
            <th>性别：</th>
            <td>{if $data.sex==0} 保密 {elseif $data.sex==1} 男
                {elseif $data.sex==2} 女 {/if}
            </td>
        </tr>
        <tr class="noborder">
            <th class="required w120"><label class="" for="contract_name">出生日期:</label></th>
            <td>{$data.birthday}</td>
            <th>联系地址：</th>
            <td>{$data.address}</td>
        </tr>

        <tr class="noborder">
            <th class="required w120"><label class="" for="contract_name">添加人:</label></th>
            <td>{$data.admin_name}</td>
            <th>更新时间：</th>
            <td>{$data.updated_at}</td>
        </tr>
        <tr class="noborder">
            <th class="required w120"><label class="" for="contract_name">登录次数:</label></th>
            <td>{$data.login_num}</td>
            <th>最后一次登录时间：</th>
            <td>{$data.login_time}</td>
        </tr>
        <tr class="noborder">
            <th class="required w120"><label class="" for="contract_name">状态:</label></th>
            <td>
                {if $data.status == '0'}
                禁用
                {else /}
                启用
                {/if}
            </td>
            <th>等级：</th>
            <td>{$gradeArr['name']}</td>
        </tr>

        <tr class="noborder">
            <th class="required w120"><label class="" for="contract_name">口号:</label></th>
            <td colspan="3">{$data.kouhao}</td>
        </tr>
        </tbody>
    </table>
    <table class="ds-default-table">
        <thead>
        <tr>
            <th colspan="6">实名认证信息</th>
        </tr>
        </thead>
        <tbody>
        <tr class="noborder">
            <th class="required w120"><label class="" for="contract_name">姓名:</label></th>
            <td>{$data.name}</td>
            <th>身份证号：</th>
            <td>{$data.idcard}</td>
        </tr>
        <tr class="noborder">
            <th class="required w120"><label class="" for="contract_name">审核人:</label></th>
            <td>{$data.status_admin_name}</td>
            <th>审核时间：</th>
            <td>{$data.status_at}</td>
        </tr>
        <tr class="noborder">
            <th class="required w120"><label class="" for="contract_name">身份证正面:</label></th>
            <td>

                {if $data.cardImgZ}
                <a href="javascript:void(0);" onclick='imgs("{$data.cardImgZ}");' >查看 </a>
                    {else/}未上传
                    {/if}

            </td>
            <th>身份证反面：</th>
            <td>
                {if $data.cardImgF}
                <a href="javascript:void(0);" onclick='imgs("{$data.cardImgF}");' >查看 </a>
                    {else/}未上传
                    {/if}
               </td>
        </tr>
        <tr class="noborder">
            <th>身份证手持：</th>
            <td>
                {if $data.cardImgS}
                <a href="javascript:void(0);" onclick='imgs("{$data.cardImgS}");' >查看 </a>
                    {else/}
                未上传
                    {/if}
                </td>
            <th>实名认证状态：</th>
            <td>{if $data.cardstatus ==0} 未认证 {elseif $data.cardstatus ==1} 认证成功
                {elseif $data.cardstatus ==2} 认证失败 {elseif $data.cardstatus ==3} 已提交信息等待认证 {/if}
            </td>
        </tr>
        <tr class="noborder">
            <th>实名认证失败原因：</th>
            <td colspan="3">{$data.cardfail_resonse}</td>
        </tr>
        <tr class="noborder">
            <th>学习或培训经历：</th>
            <td colspan="3">{$data.learning}</td>
        </tr>
        <tr class="noborder">
            <th>工作经历：</th>
            <td colspan="3">{$data.work}</td>
        </tr>
        </tbody>
    </table>
</div>
<script>
    $(function () {
        $('#file_button').click(function () {
            var files = $(this).val();
            $.ajax({
                //请求方式
                type: "POST",
                //请求地址
                url: "getWord",
                //数据，json字符串
                data: {'files': files},
                //请求成功
                success: function (result) {
                    alert(result);
                },
                //请求失败，包含具体的错误信息
                error: function (e) {
                    console.log(e.status);
                    console.log(e.responseText);
                }
            });
        });
    });

    //图片查看详情
    function imgs(img) {
        _uri = HOMESITEURL + "/Servicepersonal/imgs?img=" + img + "&status=1";
        dsLayerOpen(_uri, '原图', '600px', '420px');
    }

    /**
     * Layer 通用ifram弹出窗口
     */
    function dsLayerOpen(url, title, width, height) {
        if (!width) width = '900px';
        if (!height) height = '500px';
        layer.open({
            type: 2,
            title: title,
            area: [width, height],
            fixed: false, //不固定
            maxmin: true,
            content: url
        });
    }

</script>